package com.dao;

import java.util.List;

import com.vo.Emp;
import com.vo.User;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Select;
import org.apache.ibatis.annotations.Update;

public interface IEmpDAO {
	@Select("select * from emp")
	public List<Emp> selectAll() throws Exception;

	@Delete("delete from emp where empno = #{empno}")
	int delEmp(int empno);

	@Select("select * from emp where empno = #{empno}")
	Emp findEmpById(int epmno);

	@Update("update emp set ename = #{ename}, job = #{job}, mgr = #{mgr}, hiredate = #{hiredate}, sal = #{sal}, comm = #{comm}, deptno = #{deptno} where empno = #{empno}")
	int updateEmp(Emp emp);

//	@Insert("insert into user(id,username,sex,city) values (default,#{username},#{sex},#{city})")
//	public void insertUser(User user)throws Exception;

}
